import index from '@/http/index'
import type { AxiosRequestConfig } from 'axios';
//登录
export const LoginAccount = async(data:any)=>{
    return index({
        url:'/api/Account/LoginAccount',
        method:'post',
        params:data
    })
}
//用户列表
export const GetAccountList = async(data:any)=>{
    return index({
        url:'/api/Account/PageAccount',
        method:'get',
        params:data
    })
}
//图片验证码
export const GetCaptcha =async(data:any)=>{
    return index({
        url:'/api/Captcha/Captcha',
        method:'get',
        responseType:'blob',
        params:{
            id:data
        }
    })
}
//会议列表
export const GetMeetList = async(data:any)=>{
    return index({
        url:'/api/Meet/PagingMeet',
        method:'get',
        params:data
    })
}

//会议预约列表
export const GetAppointmentList = async(data:any)=>{
    return index({
        url:'/api/Appointments/AppointmentList',
        method:'get',
        params:data
    })
}

//部门列表
export const DepartmentList = async(data:any)=>{
    return index({
        url:'/api/Department/DepartmentList',
        method:'get',
        params:data
    })
}

//部门级联下拉
export const DepartmentTreeSel = async()=>{
    return index({
        url:'/api/Department/DepartmentTreeSel',
        method:'get',
    })
}

//获取所有在该部门下的用户
export const GetPeopleFromDepartment = async()=>{
    return index({
        url:'/api/Department/GetPeopleFromDepartment',
        method:'get',
    })
}

//获取角色部门关系列表
export const GetRoleDepartmentRelationList=async(data:any)=>{
    return index({
        url:'/api/RoleManager/RoleDepartmentRelationList',
        method:'get',
        params:data
    })
}

//权限列表
export const GetPermissionList=async()=>{
    return index({
        url:'api/Permissions/PermissionsList',
        method:'get',
    })
}

//通过角色Id获取到角色对应的权限
export const GetRoleIdForShowPermissions=async(data:any)=>{
    return index({
        url:'/api/Permissions/GetRoleIdForMissionsDetails',
        method:'get',
        params:{
            id:data
        }
    })
}


//会议审批列表
export const GetMeetProcessList=async(data:any)=>{
    return index({
        url:'/api/Appointments/MeetProcessList',
        method:'get',
        params:data
    })
}
